#include "SDL/SDL.h"

#define INFOWIDTH (160*PIXELSIZE)
#define INFOHEIGHT (224*PIXELSIZE)
#define INFOSIZE (INFOWIDTH*INFOHEIGHT)

#define WINDOWWIDTH (DISPLAYWIDTH+INFOWIDTH)
#define WINDOWHEIGHT DISPLAYHEIGHT
#define WINDOWSIZE (INFOSIZE+DISPLAYSIZE)

void initVideoExt();
void videoToSurfaceExt(SDL_Surface *surface);
void buftosurfaceExt(long *buf1, long *buf2, int w1, int w2, int wh, SDL_Surface *surface);
void pixelbuftosurfaceExt(SDL_Surface *surface);

void selectRegion(int x, int y, int w, int h);
void selectionsToPixelBuf();

void fgTilesHilightedToPixelBuf();
void bgTilesHilightedToPixelBuf();

void tileToPixelBuf(int tile, int tilex, int tiley, long *buf, int width, int height);

signed long getHScroll(int row);
signed long getVScroll();
